<template>
  <el-card class="lession-card" shadow="never">
    <el-form>
      <el-form-item label="课程名称" prop="lessionName">
        <el-input v-model="formData.lessionName" placeholder="请输入课程名称" />
      </el-form-item>
    </el-form>
    <div class="lession-card-header">
      <el-button type="primary" size="mini">发布课程</el-button>
    </div>
    <el-table :data="tableData" border style="width: 100%">
      <el-table-column type="index" label="序号" width="50" />
      <el-table-column prop="lessionId" label="课程编号" min-width="150" />
      <el-table-column prop="lessionName" label="课程名称" min-width="200" />
      <el-table-column prop="majorName" label="所属专业" min-width="180" />
      <el-table-column prop="status" label="课程状态" min-width="180" />
      <el-table-column prop="target" label="学习目标" />
      <el-table-column prop="operation" label="操作" width="200">
        <template slot-scope="">
          <el-button type="text" size="mini">编辑</el-button>
          <el-button type="text" size="mini">发布</el-button>
          <el-button type="text" size="mini">转为草稿</el-button>
          <el-button type="text" size="mini">考试安排</el-button>
          <el-button type="text" size="mini">删除</el-button>
        </template>
      </el-table-column>
    </el-table>
  </el-card>
</template>

<script>
import { lession_list_mock } from "@/components/train/mock";
export default {
  name: "LessionList",
  data() {
    return {
      tableData: lession_list_mock,
    };
  },
};
</script>
<style scoped>
.lession-card {
  width: 100%;
}
.lession-card-header {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 20px;
}
</style>
